<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <#include "../decorator/head.html"/>
    <link rel="stylesheet" href="${ctxPath}/jstree/style.min.css">
    <title>MEE-角色管理</title>
</head>
<body data-catalog="service">
<#include "../decorator/banner.html"/>
<div class="container-fluid">
    <div class="row">
        <div class="col-sm-2 sidebar">
            <#include "../decorator/sys_menu.html"/>
        </div>
        <div class="col-sm-offset-2 col-sm-10">
            <div class="main">
                <!-- 业务内容 -->
                <form method="post" id="search-form" class="form-inline form-search">
                    <label class="form-label">操作: &nbsp;&nbsp;&nbsp;&nbsp;</label>&nbsp;&nbsp;

                    <button class="btn btn-sm btn-success" name="new">增加</button>
                    <button class="btn btn-sm btn-info" name="mod">编辑</button>
                    <button class="btn btn-sm btn-danger" name="del">删除</button>
                </form>
                <div id="data-list">
                </div>

                <script type="text/cc-template" id="template-data-list">
                    <table class="table table-striped table-bordered table-hover table-condensed">
                        <thead>
                        <tr>
                            <th width="40px;">选择</th>
                            <th>权限名称</th>
                            <th>权限描述</th>
                            <th>状态</th>
                            <th>更新时间</th>
                            <th>创建时间</th>
                        </tr>
                        </thead>
                        <tbody>
                        {{#each this}}
                        <tr>
                            <th><input type="radio" name="sel" value="{{@index}}"></th>
                            <td>{{role_name}}</td>
                            <td>{{role_desc}}</td>

                            {{#if status}}
                                <td style="color:green;font-weight:bold;">开启</td>
                            {{else}}
                                <td>关闭</td>
                            {{/if}}

                            <td>{{update_date}}</td>
                            <td>{{create_date}}</td>
                        </tr>
                        {{/each}}
                        </tbody>
                    </table>
                    <!--
                    <form class="form-paging">
                        <label>当前第 {{idx}} 页 / 总 {{pageCount}} 页, 每页
                            &nbsp;<select class="input-sm" name="pageSize" pageSize="{{size}}"></select>&nbsp;条</label>
                        <span class="seprator"></span>
                        <button name="firstpage" class="btn btn-sm">首页</button>
                        <button name="prevpage" class="btn btn-sm">上一页</button>
                        <button name="nextpage" class="btn btn-sm">下一页</button>
                        <button name="lastpage" class="btn btn-sm">末页</button>
                        <span class="seprator"></span>
                        <label>第<input type="text" name="pageIdx" class="page" value="{{index}}" size="3"></input>页</label>
                        <button name="gopage" class="btn btn-sm">GO</button>
                    </form>
                    -->
                </script>
                <script type="text/javascript">
                // document.querySelector(".menu-rights").parentNode.nextElementSibling.style.display="block";
                $(function(){
                    seajs.use("sys/role", function(role){
                        role.init();
                    });
                });
                </script>
                <script type="text/javascript" src="${ctxPath}/jstree/jstree.js"></script>
            </div>
        </div>
    </div>
</div>
</body>
<!-- 底部静态 -->
<#include "../decorator/foot.html"/>
</html>
